package com.example.entity;


import com.example.utils.DateUtil;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import java.text.ParseException;
import java.util.Date;

//员工表
@Data
@AllArgsConstructor
@NoArgsConstructor
@Entity
@Table
public class Employee {

    @Column(name = "employee_id",length = 11,nullable = false)
    private Integer id;

    @Column(name = "user_id",length = 11,nullable = false)
    private Integer userId;

    @Column
    private String lastName;

    @Column
    private String email;

    @Column
    private Integer gender; //0 女   1 男

    @Column(name = "department_id")
    private Integer departmentId;

    @Column(name = "department_name")
    private String departmentName;

    @Column
    private Date birth;

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private int idd;

}
